#!/usr/bin/python

import numpy as np
import matplotlib
import matplotlib.pyplot as plt

from mpl_toolkits.mplot3d import Axes3D


def main():
    infile = open('data')

    # read data

    data_1 = []
    data_2 = []
    ys = []
    for line in infile.readlines():
        tok = line.split()
        ys.append(float(tok[0]))
        label_value_1 = tok[1].split(':')
        label_value_2 = tok[2].split(':')
        data_1.append(float(label_value_1[1]))
        data_2.append(float(label_value_2[1]))

    infile.close()

    # plot data

    fig = plt.figure()
    ax = Axes3D(fig)
    ax.scatter(data_1, data_2, ys)
    plt.show()  


if __name__ == "__main__":
    main()
